package com.wsx.carrot.controller;


import com.wsx.carrot.data.BaseWebData;
import org.springframework.web.bind.annotation.ExceptionHandler;

/**
 * 抽象的父类接收器，定义全局的特性
 * Created by wangshuaixin on 17/9/4.
 */
public abstract class AbstractBaseController {

    @ExceptionHandler
    public BaseWebData exceptionHandler(Exception ex) {
        //记录日志
        return new BaseWebData(WebInterface.ERROR);
    }
}
